package chapitre3;

public class Execise1 {

	static int ternary(int i) {
		return i < 10 ? i * 100 : i * 10;
		}
	static int alternative(int i) {
		if (i < 10)
		return i * 100;
		else
		return i * 10;
		}
	public static void main(String[] args){		
		int a;
		int x=1;
		int y=3;
		int z=5;
		a = x + y - 2/2 + z;
		System.out.println(a);
		a = x + (y - 2)/(2 + z);
		System.out.println(a);
		
		int int1=9;
		int int2=11;
		System.out.println(alternative(int1));
		System.out.println(ternary(int2));
		
	}
}
